clc
clear
MC35 = load('MC35.mat');
MC75 = load('MC75.mat');
MC100 = load('MC100.mat');
n1 = 20000;
n2 = 210;

tMC = nan(n1,n2);
lonMC = nan(n1,n2);
latMC = nan(n1,n2);
altMC = nan(n1,n2);

deltaH = nan(1,n2);
deltaV = nan(1,n2);
deltaS = nan(1,n2);
deltat = nan(1,n2);

deltaH(1:100) = MC100.deltaH;
deltaH(101:135) = MC35.deltaH(1:35);
deltaH(136:210) = MC75.deltaH(1:75);

deltaV(1:100) = MC100.deltaV;
deltaV(101:135) = MC35.deltaV(1:35);
deltaV(136:210) = MC75.deltaV(1:75);

deltaS(1:100) = MC100.deltaS;
deltaS(101:135) = MC35.deltaS(1:35);
deltaS(136:210) = MC75.deltaS(1:75);

deltat(1:100) = MC100.deltat;
deltat(101:135) = MC35.deltat(1:35);
deltat(136:210) = MC75.deltat(1:75);

tMC(1:n1,1:100) = MC100.tMC;
tMC(1:n1,101:135) = MC35.tMC(1:n1,1:35);
tMC(1:n1,136:210) = MC75.tMC(1:n1,1:75);

lonMC(1:n1,1:100) = MC100.lonMC;
lonMC(1:n1,101:135) = MC35.lonMC(1:n1,1:35);
lonMC(1:n1,136:210) = MC75.lonMC(1:n1,1:75);

latMC(1:n1,1:100) = MC100.latMC;
latMC(1:n1,101:135) = MC35.latMC(1:n1,1:35);
latMC(1:n1,136:210) = MC75.latMC(1:n1,1:75);

altMC(1:n1,1:100) = MC100.altMC;
altMC(1:n1,101:135) = MC35.altMC(1:n1,1:35);
altMC(1:n1,136:210) = MC75.altMC(1:n1,1:75);

save('MC.mat', 'deltaV');
save('MC.mat', 'deltaH','-append');
save('MC.mat', 'deltaS','-append');
save('MC.mat', 'deltat','-append');
save('MC.mat', 'tMC','-append');
save('MC.mat', 'lonMC','-append');
save('MC.mat', 'latMC','-append');
save('MC.mat', 'altMC','-append');